package com.hzt.business.controller;

import com.hzt.business.domain.Outport;
import com.hzt.business.service.OutportService;
import com.hzt.business.vo.OutportVo;
import com.hzt.system.common.ActiveUser;
import com.hzt.system.common.ResultObj;
import org.apache.shiro.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Date;

/**
*
* @Author:hzt
* @Date:6:52 下午 2020/7/25
*/
@RequestMapping("api/outport")
@RestController
public class OutportController {

    @Autowired
    private OutportService outportService;


    @RequestMapping("loadAllOutport")
    public Object loadAllOutport(OutportVo outportVo){
        return this.outportService.queryAllOutport(outportVo);
    }


    @RequestMapping("addOutport")
    public ResultObj addOutport(Outport outport){

        try {
            this.outportService.saveOutport(outport);
            return  ResultObj.ADD_SUCCESS;
        } catch (Exception e) {
            e.printStackTrace();
            return  ResultObj.ADD_SUCCESS;
        }
    }



}
